package com.nondo.rdp.finance.model.circle;

import java.util.ArrayList;
import java.util.List;

import com.nondo.rdp.finance.domain.circle.CircleUp;
import com.nondo.rdp.auth.model.UserBeanInner;

/**
 * 金融圈-说说-点赞
 */
public class CircleUpBean {
	private Long id; // 主键ID
	private UserBeanInner user; // 用户信息

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public UserBeanInner getUser() {
		return user;
	}

	public void setUser(UserBeanInner user) {
		this.user = user;
	}

	public static List<CircleUpBean> covert2BeanList(List<CircleUp> ups) {
		List<CircleUpBean> upBeans = new ArrayList<CircleUpBean>();
		for (CircleUp up : ups) {
			CircleUpBean upBean = CircleUpBean.covert2Bean(up);
			upBeans.add(upBean);
		}
		return upBeans;
	}

	public static CircleUpBean covert2Bean(CircleUp up) {
		CircleUpBean upBean = new CircleUpBean();
		upBean.setId(up.getId());
		UserBeanInner user = UserBeanInner.covert2Bean(up.getUser());
		upBean.setUser(user);
		return upBean;
	}
}
